home *** CD-ROM | disk | FTP | other *** search
/ Columbia Kermit / kermit.zip / newsgroups / misc.19960715-19961006 / 000116_news@columbia.edu _Wed Jul 31 13:32:34 1996.msg < prev    next >
Internet Message Format  |  2020-01-01  |  3KB

  1. Return-Path: news@columbia.edu
  2. Received: from newsmaster.cc.columbia.edu (newsmaster.cc.columbia.edu [128.59.35.30]) by watsun.cc.columbia.edu (8.7.5/8.7.3) with ESMTP id NAA05609 for <kermit.misc@watsun.cc.columbia.edu>; Wed, 31 Jul 1996 13:32:34 -0400 (EDT)
  3. Received: (from news@localhost) by newsmaster.cc.columbia.edu (8.7.5/8.7.3) id NAA11362 for kermit.misc@watsun; Wed, 31 Jul 1996 13:32:33 -0400 (EDT)
  4. Path: news.columbia.edu!news.new-york.net!news.iag.net!newsfeeder.sdsu.edu!nntp04.primenet.com!news.shkoo.com!nntp.primenet.com!news.cais.net!news.mathworks.com!enews.sgi.com!decwrl!nntp.crl.com!crl.crl.com!not-for-mail
  5. From: oak@crl.com (Tony Gonzalez)
  6. Newsgroups: comp.protocols.kermit.misc
  7. Subject: ckermit: record (learn) macro?
  8. Date: 31 Jul 1996 01:03:55 -0700
  9. Organization: CRL Network Services      (415) 705-6060  [Login: guest]
  10. Lines: 56
  11. Message-ID: <4tn41b$mqd@crl.crl.com>
  12. NNTP-Posting-Host: crl.com
  13. X-Newsreader: TIN [version 1.2 PL2]
  14.  
  15. In my dos com program I was able to dial and login to my unix shell account
  16. and all could be recorded in a macro file which I could later execute.  So
  17. the whole macro would automatically be created.  Can I do this in ckermit?
  18.  
  19. The script language looks Greek to me and doing something like this really
  20. helps learn the macro language fast and to the specific needs of the
  21. individual.
  22.  
  23. The closest sample macro I seen in the docs to what I want to do is
  24. the sample script below, but I hesitate to use it because it's not commented
  25. and I really don't know what's going on in some of the steps,
  26. also, I'd have to add something like "DIAL MYISP" to the macro.
  27.  
  28. Anyone have a sample unix shell account dial in script?
  29.  
  30.  
  31. Thanks
  32.  
  33. -Tony
  34.  
  35.  
  36. --- this is the closest thing to a unix shell account dial-in macro I saw ---
  37.  
  38.  
  39. COMMENT - UNIXLOGIN macro.  Arguments:
  40. ; \%1 = user ID
  41. ; \%2 = password
  42. ;
  43. def UNIXLOGIN if < \v(argc) 2 end 1 Usage: \%0 userid password,-
  44.     if eq \fcode(\%2) 32 asg \%2 \fsubst(\%2,2), -
  45.     while not def \%2 { -
  46.         askq \%2 { \%1's password: } -
  47.     },-
  48.     set parity none,-
  49.     set duplex full,-
  50.     set handshake none,-
  51.     set case on,-
  52.     out \13,-
  53.     set input timeout proceed,-
  54.     for \%i 1 15 1 { -
  55.         in 5 login:,-
  56.         if success goto DOLOGIN,-
  57.         output \\B -
  58.     },-
  59.     end 1 No login prompt,-
  60. :DOLOGIN,-
  61.     out \%1\13,-
  62.     inp 5 Password:,-
  63.     if fail end 1 No password prompt,-
  64.     out \%2\13,-
  65.     def \%2,-
  66.     if not def \%3 asg \%3 {\13\10$ },-
  67.     inp 60 \%3,-
  68.     if fail end 1 No system prompt,-
  69.     echo, echo Login successful.
  70.